FROM java:8-jdk

MAINTAINER BJB-VR

RUN mkdir -p /config
COPY /datasync-client/config /config
ADD /datasync-client/xr-datasync-client.jar /opt/xr-datasync-client.jar
RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
RUN echo 'Asia/Shanghai' >/etc/timezone

# PORT
EXPOSE 8088

#设置变量 JAVA_OPTS
ENV JAVA_OPTS="-Xmx512M -Xms512M -Xmn256M -XX:MaxMetaspaceSize=192M -XX:MetaspaceSize=192M"

#启动命令
ENTRYPOINT java ${JAVA_OPTS} -jar /opt/xr-datasync-client.jar